Skip to content

perf(reader): cache OpenDAL Operators#2177

Draft
mbutrovich wants to merge 1 commit intoapache:mainfrom
mbutrovich:operator_caching
Draft

perf(reader): cache OpenDAL Operators#2177
mbutrovich wants to merge 1 commit intoapache:mainfrom
mbutrovich:operator_caching

Conversation

@mbutrovich
Copy link
Copy Markdown
Collaborator

Draft/POC for discussion, particularly @Xuanwo and @CTTY.

Which issue does this PR close?

What changes are included in this PR?

  • Added operator_cache: Arc<Mutex<HashMap<String, Operator>>> to S3, Gcs, Oss, and Azdls variants of OpenDalStorage
  • Added get_or_create_operator() helper that checks the cache by bucket/container name before building a new operator
  • create_operator() now caches operators per bucket for S3/GCS/OSS and per filesystem for Azdls
  • RetryLayer is applied once when an operator is created and cached, rather than on every call
  • Memory and LocalFs don't use the cache (Memory clones a shared operator, LocalFs is local)

Are these changes tested?

Existing tests.

@mbutrovich mbutrovich changed the title Extract more changes from reader_perf. perf(reader): Cache OpenDAL Operators Feb 24, 2026
@mbutrovich mbutrovich changed the title perf(reader): Cache OpenDAL Operators perf(reader): cache OpenDAL Operators Feb 24, 2026
@mbutrovich mbutrovich self-assigned this Feb 24, 2026
@github-actions
Copy link
Copy Markdown
Contributor

This pull request has been marked as stale due to 30 days of inactivity. It will be closed in 1 week if no further activity occurs. If you think that’s incorrect or this pull request requires a review, please simply write any comment. If closed, you can revive the PR at any time and @mention a reviewer or discuss it on the dev@iceberg.apache.org list. Thank you for your contributions.

@github-actions github-actions bot added the stale label Mar 27, 2026
@mbutrovich
Copy link
Copy Markdown
Collaborator Author

Still thinking about this one and will revisit with the Storage trait work.

@github-actions github-actions bot removed the stale label Mar 28, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant